/*
 * DRACOON API
 * REST Web Services for DRACOON<br><br>This page provides an overview of all available and documented DRACOON APIs, which are grouped by tags.<br>Each tag provides a collection of APIs that are intended for a specific area of the DRACOON.<br><br><a title='Developer Information' href='https://developer.dracoon.com'>Developer Information</a>&emsp;&emsp;<a title='Get SDKs on GitHub' href='https://github.com/dracoon'>Get SDKs on GitHub</a><br><br><a title='Terms of service' href='https://www.dracoon.com/terms/general-terms-and-conditions/'>Terms of service</a>
 *
 * OpenAPI spec version: 4.45.1
 * 
 *
 * NOTE: This class is auto generated by the swagger code generator program.
 * https://github.com/swagger-api/swagger-codegen.git
 * Do not edit the class manually.
 */

package ch.cyberduck.core.sds.io.swagger.client.model;

import java.util.Objects;
import java.util.Arrays;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;
import io.swagger.v3.oas.annotations.media.Schema;
import org.joda.time.DateTime;
/**
 * Contains the save-to-send-out information of a MFA-setup
 */
@Schema(description = "Contains the save-to-send-out information of a MFA-setup")

public class MfaSetupStatus {
  @JsonProperty("id")
  private Long id = null;

  @JsonProperty("createdAt")
  private DateTime createdAt = null;

  /**
   * Type of second factor authentication
   */
  public enum MfaTypeEnum {
    TOTP("TOTP"),
    EMERGENCY("EMERGENCY"),
    U2F("U2F");

    private String value;

    MfaTypeEnum(String value) {
      this.value = value;
    }
    @JsonValue
    public String getValue() {
      return value;
    }

    @Override
    public String toString() {
      return String.valueOf(value);
    }
    @JsonCreator
    public static MfaTypeEnum fromValue(String input) {
      for (MfaTypeEnum b : MfaTypeEnum.values()) {
        if (b.value.equals(input)) {
          return b;
        }
      }
      return null;
    }

  }  @JsonProperty("mfaType")
  private MfaTypeEnum mfaType = null;

  @JsonProperty("name")
  private String name = null;

  public MfaSetupStatus id(Long id) {
    this.id = id;
    return this;
  }

   /**
   * ID
   * @return id
  **/
  @Schema(required = true, description = "ID")
  public Long getId() {
    return id;
  }

  public void setId(Long id) {
    this.id = id;
  }

  public MfaSetupStatus createdAt(DateTime createdAt) {
    this.createdAt = createdAt;
    return this;
  }

   /**
   * Creation date
   * @return createdAt
  **/
  @Schema(required = true, description = "Creation date")
  public DateTime getCreatedAt() {
    return createdAt;
  }

  public void setCreatedAt(DateTime createdAt) {
    this.createdAt = createdAt;
  }

  public MfaSetupStatus mfaType(MfaTypeEnum mfaType) {
    this.mfaType = mfaType;
    return this;
  }

   /**
   * Type of second factor authentication
   * @return mfaType
  **/
  @Schema(required = true, description = "Type of second factor authentication")
  public MfaTypeEnum getMfaType() {
    return mfaType;
  }

  public void setMfaType(MfaTypeEnum mfaType) {
    this.mfaType = mfaType;
  }

  public MfaSetupStatus name(String name) {
    this.name = name;
    return this;
  }

   /**
   * A name to identify the MFA setup by the user. Default is MFA-type followed by a number
   * @return name
  **/
  @Schema(required = true, description = "A name to identify the MFA setup by the user. Default is MFA-type followed by a number")
  public String getName() {
    return name;
  }

  public void setName(String name) {
    this.name = name;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    MfaSetupStatus mfaSetupStatus = (MfaSetupStatus) o;
    return Objects.equals(this.id, mfaSetupStatus.id) &&
        Objects.equals(this.createdAt, mfaSetupStatus.createdAt) &&
        Objects.equals(this.mfaType, mfaSetupStatus.mfaType) &&
        Objects.equals(this.name, mfaSetupStatus.name);
  }

  @Override
  public int hashCode() {
    return Objects.hash(id, createdAt, mfaType, name);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class MfaSetupStatus {\n");
    
    sb.append("    id: ").append(toIndentedString(id)).append("\n");
    sb.append("    createdAt: ").append(toIndentedString(createdAt)).append("\n");
    sb.append("    mfaType: ").append(toIndentedString(mfaType)).append("\n");
    sb.append("    name: ").append(toIndentedString(name)).append("\n");
    sb.append("}");
    return sb.toString();
  }

  /**
   * Convert the given object to string with each line indented by 4 spaces
   * (except the first line).
   */
  private String toIndentedString(java.lang.Object o) {
    if (o == null) {
      return "null";
    }
    return o.toString().replace("\n", "\n    ");
  }

}
